<?php defined('_JEXEC') or die('Restricted access');
 header("Content-Type: application/xml; charset=ISO-8859-1");
echo '<?xml';
?> version="1.0" encoding="utf-8"?>
<rss version="2.0">
	<channel>
		<title><![CDATA[<?php echo $this->project->name; ?> - <?php echo JText::_('COM_JHTRAQ_TIMELINE');?>]]></title>
		<description><![CDATA[<?php echo $this->project->name; ?> - <?php echo JText::_('COM_JHTRAQ_TIMELINE');?>]]></description>
		<link><![CDATA[<?php echo JRoute::_(JURI::base() . 'index.php?option=com_jhtraq&view=projects&project='.$this->project->slug) ;?>]]></link>
		<lastBuildDate><?PHP echo date("l, jS F Y",time())?></lastBuildDate>
		<generator>Jh Traq</generator>
                <?php foreach($this->days as $day) { ?>
		<item>
			<title><?PHP echo date("l, jS F Y",$day['timestamp'])?></title>
			<link><![CDATA[<?php echo JRoute::_(JURI::base() . 'index.php?option=com_jhtraq&view=projects&project='.$this->project->slug) ;?>]]></link>
			<description><![CDATA[<?php foreach($day['changes'] as $change) { ?>
				<?php echo date("h:iA",$change['timestamp'])?> <a href="<?php echo $change['url']?>"><?php echo $change['text']?></a><br>
			<?php } ?>]]></description>
			
		</item>
		<?php } ?>
	</channel>
</rss>
<?php exit;?>

<p></p>
<div class="componentheading">
	<?php echo $this->project->name; ?> - <?php echo JText::_('COM_JHTRAQ_TIMELINE');?>
</div>
<?php foreach($this->days as $day) { ?>
		<div class="day">
			<h3><?PHP echo date("l, jS F Y",$day['timestamp'])?></h3>
			<ul>
			<?php foreach($day['changes'] as $change) { ?>
				<li><?php echo date("h:iA",$change['timestamp'])?> <a href="<?php echo $change['url']?>"><?php echo $change['text']?></a></li>
			<?php } ?>
			</ul>
		</div>
		<?php } ?>